Skip to content

feat: Added submission history API and extended enrollment API to support grading and finished flags. - #31491

Merged
Agrendalath merged 2 commits into
openedx:masterfrom
open-craft:farhaan/upstream-submission-history-api
Feb 17, 2023
Merged

feat: Added submission history API and extended enrollment API to support grading and finished flags.#31491
Agrendalath merged 2 commits into
openedx:masterfrom
open-craft:farhaan/upstream-submission-history-api

Conversation

@farhaanbukhsh

@farhaanbukhsh farhaanbukhsh commented Jan 3, 2023

Copy link
Copy Markdown
Member

Description

These changes:

  1. Fixes the pagination issue with enrollment API and adds course grades and finished flags to the API.
  2. Adds submission history API which gives the history of problem submission.
  3. Adds Section Grades Breakdown API which gives the section grade breakdown for each course enrollment.

Enrollment API is enhanced to add grades for the course and the finished status for the course. We have also tried to fix
the pagination issue with the same.

Submission API is added to retrieve the submission history of the problem by a user. And course grade status end point help us to retrieve the information about course and how a student is doing in the course.

Supporting information

BB-5591

open-craft@c8713a5

#18838

Testing instructions

Deadline

"None" if there's no rush, or provide a specific date or event (and reason) if there is one.

Other information

TBD

Reviewer

@farhaanbukhsh farhaanbukhsh self-assigned this Jan 3, 2023
@openedx-webhooks

Copy link
Copy Markdown

Thanks for the pull request, @farhaanbukhsh! Please note that it may take us up to several weeks or months to complete a review and merge your PR.

Feel free to add as much of the following information to the ticket as you can:

  • supporting documentation
  • Open edX discussion forum threads
  • timeline information ("this must be merged by XX date", and why that is)
  • partner information ("this is a course on edx.org")
  • any other information that can help Product understand the context for the PR

All technical communication about the code itself will be done via the GitHub pull request interface. As a reminder, our process documentation is here.

Please let us know once your PR is ready for our review and all tests are green.

@openedx-webhooks openedx-webhooks added the open-source-contribution PR author is not from Axim or 2U label Jan 3, 2023
@mphilbrick211

Copy link
Copy Markdown

Hi @farhaanbukhsh - is this ready for review?

@farhaanbukhsh

Copy link
Copy Markdown
Member Author

@mphilbrick211 This is going through internal review, :) once that is done I will ping you, hope that is okay. 😄

Comment thread openedx/core/djangoapps/enrollments/serializers.py Outdated
Comment thread openedx/core/djangoapps/enrollments/serializers.py Outdated
Comment thread openedx/core/djangoapps/enrollments/serializers.py Outdated
Comment thread openedx/core/djangoapps/enrollments/serializers.py Outdated
Comment thread openedx/core/djangoapps/enrollments/tests/test_views.py Outdated
Comment thread openedx/core/djangoapps/enrollments/paginators.py
Comment thread openedx/core/djangoapps/enrollments/views.py Outdated
Comment thread openedx/core/djangoapps/enrollments/views.py Outdated
Comment thread openedx/core/djangoapps/enrollments/serializers.py Outdated
Comment thread openedx/core/djangoapps/enrollments/urls.py Outdated
@mphilbrick211

Copy link
Copy Markdown

Hi @farhaanbukhsh! Just following up on the changes requested.

@farhaanbukhsh

Copy link
Copy Markdown
Member Author

Hi @farhaanbukhsh! Just following up on the changes requested.

Hi @mphilbrick211 thank you for checking up on the PR 😄 I am making those changes and should be up for another review soon. :)

@farhaanbukhsh
farhaanbukhsh force-pushed the farhaan/upstream-submission-history-api branch from ecf386c to bf496ce Compare February 6, 2023 05:18
@farhaanbukhsh

Copy link
Copy Markdown
Member Author

@Agrendalath This PR is up for another review, I am still figuring out, why are the test not running and why is it throwing Cannot import ItemFactory error in the tests :)

@farhaanbukhsh
farhaanbukhsh force-pushed the farhaan/upstream-submission-history-api branch from bf496ce to 0d9f1c9 Compare February 6, 2023 05:43
Comment thread lms/djangoapps/courseware/access_utils.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/views.py Outdated
@mphilbrick211 mphilbrick211 added the waiting on author PR author needs to resolve review requests, answer questions, fix tests, etc. label Feb 7, 2023

@Agrendalath Agrendalath left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@farhaanbukhsh, there are still a few bugs, but it's looking much better.

Comment thread lms/djangoapps/grades/rest_api/v1/urls.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/tests/test_views.py Outdated

@Agrendalath Agrendalath left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@farhaanbukhsh, thank you for your persistence! Please squash your commits into logical chunks before we merge.

👍

  • I tested this: tested both APIs locally; checked that the pagination works correctly for the enrollments API
  • I read through the code
  • I checked for accessibility issues: n/a
  • Includes documentation
  • I made sure any change in configuration variables is reflected in the corresponding client's configuration-secure repository: n/a

Comment thread lms/djangoapps/grades/rest_api/v1/tests/test_views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/tests/test_views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/tests/test_views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/tests/test_views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/tests/test_views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/tests/test_views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/tests/test_views.py Outdated
Comment thread lms/djangoapps/grades/rest_api/v1/tests/test_views.py Outdated
@farhaanbukhsh
farhaanbukhsh force-pushed the farhaan/upstream-submission-history-api branch from 7a23d62 to a0e3e19 Compare February 17, 2023 06:16
Signed-off-by: Farhaan Bukhsh <farhaan@opencraft.com>
…kdown.

This feature helps to add submission history for each ProblemBlock in
the course. It also adds API for section grades breakdown, that gives
information about grades scored in each section of the course.

Signed-off-by: Farhaan Bukhsh <farhaan@opencraft.com>
@farhaanbukhsh
farhaanbukhsh force-pushed the farhaan/upstream-submission-history-api branch from a0e3e19 to 5e24f5d Compare February 17, 2023 06:19
@Agrendalath
Agrendalath merged commit ffc8c02 into openedx:master Feb 17, 2023
@Agrendalath
Agrendalath deleted the farhaan/upstream-submission-history-api branch February 17, 2023 13:21
@openedx-webhooks

Copy link
Copy Markdown

@farhaanbukhsh 🎉 Your pull request was merged! Please take a moment to answer a two question survey so we can improve your experience in the future.

@edx-pipeline-bot

Copy link
Copy Markdown
Contributor

EdX Release Notice: This PR has been deployed to the staging environment in preparation for a release to production.

@edx-pipeline-bot

Copy link
Copy Markdown
Contributor

EdX Release Notice: This PR has been deployed to the production environment.

1 similar comment
@edx-pipeline-bot

Copy link
Copy Markdown
Contributor

EdX Release Notice: This PR has been deployed to the production environment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changes requested open-source-contribution PR author is not from Axim or 2U waiting on author PR author needs to resolve review requests, answer questions, fix tests, etc.

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

5 participants